package com.zy.learn.bean;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

@Component
public class Team {

	private String termId = "123";

	private String teamName = "测试组";


	//	@Autowired
	private Person person;


	public String getTermId() {
		return termId;
	}

	public void setTermId(String termId) {
		this.termId = termId;
	}

	public String getTeamName() {
		return teamName;
	}

	@Override
	public String toString() {
		return "Team{" +
				"termId='" + termId + '\'' +
				", teamName='" + teamName + '\'' +
				", person=" + person +
				'}';
	}

	public void setTeamName(String teamName) {
		this.teamName = teamName;
	}

	public Person getPerson() {
		return person;
	}

	public void setPerson(Person person) {
		this.person = person;
	}

	public Team() {
		System.out.println("Team empty construct...");
	}

	public Team(String termId, String teamName) {
		this.termId = termId;
		this.teamName = teamName;
	}

	@Autowired
	public Team(Person person) {
		this.person = person;
	}
}
